
import Vue from "vue";
import VueRouter from "vue-router";
import Home from "../views/home/index.vue"; // 主页
import TaskWork from "../views/taskWork/index.vue"; // 任务工作
import ContractPerformance from "../views/contractPerformance/index.vue"; // 合同履约
import PerformanceRecords from "../views/performanceRecords/index.vue"; // 履约记录

Vue.use(VueRouter);

const routes = [
  {
    path: "/home",
    name: "indexHome",
    component: Home,
    children: [
      {
        path: "/taskWork",
        name: "taskWork",
        component: TaskWork,
      }, {
        path: "/contractPerformance",
        name: "contractPerformance",
        component: ContractPerformance,
      },
      {
        path: "/performanceRecords",
        name: "performanceRecords",
        component: PerformanceRecords,
      }
    ]
  },


];

const router = new VueRouter({
  mode: "history",
  base: process.env.BASE_URL,
  routes,
});

export default router;
